package cn.how2j.springcloud.service;


import cn.how2j.springcloud.mapper.UserMapper;
import cn.how2j.springcloud.pojo.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @Author:wjup
 * @Date: 2018/9/26 0026
 * @Time: 15:23
 */
@Service
public class UserService {
    @Autowired
    UserMapper userMapper;

    public User Sel(int id) {
        return userMapper.Sel(id);
    }

    public void insert(User user) {
        userMapper.insert(user);
    }

    public List<String> select(String realName) {
        return userMapper.selectByRealName(realName);
    }
}
